package com.itheima.reggie.entity;

import com.alibaba.excel.annotation.ExcelProperty;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import lombok.Data;

import java.time.LocalDateTime;
// 提取 公共字段
@Data
public class Fu {

    // @JsonSerialize(using = ToStringSerializer.class)
    private Long id;

    //创建时间
    @ExcelProperty(value = "创建时间"/*,converter = LocalDateStringConverter.class*/)
    @TableField(fill = FieldFill.INSERT)
    // @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;

    //更新时间
    @ExcelProperty(value = "更新时间"/*,converter = LocalDateStringConverter.class*/)
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime updateTime;

    //创建人
    @ExcelProperty(value = "创建人")
    @TableField(fill = FieldFill.INSERT)
    private Long createUser;

    //修改人
    @ExcelProperty(value = "修改人")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Long updateUser;

}
